package com.yang.service.impl;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.yang.dao.UserDao;
import com.yang.model.User;
import com.yang.service.UserService;

@Service
public class UserServiceImpl implements UserService {

	@Resource
	private UserDao userDao;
	
	@Override
	public boolean login(User user) {
		return userDao.queryUserByUsernameAndPassword(user.getUsername(),user.getPassword()).size()==1;
	}


}
